<?php

/**
 * ViewRaidPlayers form base class.
 *
 * @method ViewRaidPlayers getObject() Returns the current form's model object
 *
 * @package    raidpoints
 * @subpackage form
 * @author     David Driscoll
 * @version    SVN: $Id: sfDoctrineFormGeneratedTemplate.php 24171 2009-11-19 16:37:50Z Kris.Wallsmith $
 */
abstract class BaseViewRaidPlayersForm extends BaseFormDoctrine
{
  public function setup()
  {
    $this->setWidgets(array(
      'id'                 => new sfWidgetFormInputHidden(),
      'altid'              => new sfWidgetFormInputText(),
      'name'               => new sfWidgetFormInputText(),
      'fullname'           => new sfWidgetFormInputText(),
      'guildedflag'        => new sfWidgetFormInputCheckbox(),
      'created_by'         => new sfWidgetFormInputText(),
      'updated_by'         => new sfWidgetFormInputText(),
      'classid'            => new sfWidgetFormInputText(),
      'genderid'           => new sfWidgetFormInputText(),
      'raceid'             => new sfWidgetFormInputText(),
      'rankid'             => new sfWidgetFormInputText(),
      'talentid'           => new sfWidgetFormInputText(),
      'talentindex'        => new sfWidgetFormInputText(),
      'talentname'         => new sfWidgetFormInputText(),
      'talentactive'       => new sfWidgetFormInputCheckbox(),
      'talentmainspec'     => new sfWidgetFormInputCheckbox(),
      'talenttankspec'     => new sfWidgetFormInputCheckbox(),
      'talentgroup'        => new sfWidgetFormInputText(),
      'talentspec'         => new sfWidgetFormInputText(),
      'talenturl'          => new sfWidgetFormInputText(),
      'pclass'             => new sfWidgetFormInputText(),
      'gender'             => new sfWidgetFormInputText(),
      'race'               => new sfWidgetFormInputText(),
      'rank'               => new sfWidgetFormInputText(),
      'altrank'            => new sfWidgetFormInputText(),
      'ranksort'           => new sfWidgetFormInputText(),
      'raidid'             => new sfWidgetFormInputText(),
      'raid'               => new sfWidgetFormInputHidden(),
      'raidname'           => new sfWidgetFormInputText(),
      'raidslug'           => new sfWidgetFormInputText(),
      'raidserver'         => new sfWidgetFormInputText(),
      'raidvisible'        => new sfWidgetFormInputCheckbox(),
      'points'             => new sfWidgetFormInputText(),
      'lifetime'           => new sfWidgetFormInputText(),
      'decay'              => new sfWidgetFormInputText(),
      'normalize'          => new sfWidgetFormInputText(),
      'lifetimeattendance' => new sfWidgetFormInputText(),
      '30day'              => new sfWidgetFormInputText(),
      '60day'              => new sfWidgetFormInputText(),
      '90day'              => new sfWidgetFormInputText(),
      '120day'             => new sfWidgetFormInputText(),
    ));

    $this->setValidators(array(
      'id'                 => new sfValidatorDoctrineChoice(array('model' => $this->getModelName(), 'column' => 'id', 'required' => false)),
      'altid'              => new sfValidatorInteger(),
      'name'               => new sfValidatorString(array('max_length' => 50)),
      'fullname'           => new sfValidatorString(array('max_length' => 50)),
      'guildedflag'        => new sfValidatorBoolean(array('required' => false)),
      'created_by'         => new sfValidatorInteger(),
      'updated_by'         => new sfValidatorInteger(),
      'classid'            => new sfValidatorInteger(),
      'genderid'           => new sfValidatorInteger(),
      'raceid'             => new sfValidatorInteger(),
      'rankid'             => new sfValidatorInteger(),
      'talentid'           => new sfValidatorInteger(array('required' => false)),
      'talentindex'        => new sfValidatorInteger(array('required' => false)),
      'talentname'         => new sfValidatorString(array('max_length' => 25, 'required' => false)),
      'talentactive'       => new sfValidatorBoolean(array('required' => false)),
      'talentmainspec'     => new sfValidatorBoolean(array('required' => false)),
      'talenttankspec'     => new sfValidatorBoolean(array('required' => false)),
      'talentgroup'        => new sfValidatorInteger(array('required' => false)),
      'talentspec'         => new sfValidatorString(array('max_length' => 8, 'required' => false)),
      'talenturl'          => new sfValidatorString(array('max_length' => 255, 'required' => false)),
      'pclass'             => new sfValidatorString(array('max_length' => 25)),
      'gender'             => new sfValidatorString(array('max_length' => 15)),
      'race'               => new sfValidatorString(array('max_length' => 50)),
      'rank'               => new sfValidatorString(array('max_length' => 15)),
      'altrank'            => new sfValidatorInteger(),
      'ranksort'           => new sfValidatorInteger(),
      'raidid'             => new sfValidatorInteger(),
      'raid'               => new sfValidatorDoctrineChoice(array('model' => $this->getModelName(), 'column' => 'raid', 'required' => false)),
      'raidname'           => new sfValidatorString(array('max_length' => 255)),
      'raidslug'           => new sfValidatorString(array('max_length' => 255)),
      'raidserver'         => new sfValidatorString(array('max_length' => 255)),
      'raidvisible'        => new sfValidatorBoolean(),
      'points'             => new sfValidatorInteger(array('required' => false)),
      'lifetime'           => new sfValidatorInteger(array('required' => false)),
      'decay'              => new sfValidatorInteger(array('required' => false)),
      'normalize'          => new sfValidatorInteger(array('required' => false)),
      'lifetimeattendance' => new sfValidatorInteger(array('required' => false)),
      '30day'              => new sfValidatorInteger(array('required' => false)),
      '60day'              => new sfValidatorInteger(array('required' => false)),
      '90day'              => new sfValidatorInteger(array('required' => false)),
      '120day'             => new sfValidatorInteger(array('required' => false)),
    ));

    $this->widgetSchema->setNameFormat('view_raid_players[%s]');

    $this->errorSchema = new sfValidatorErrorSchema($this->validatorSchema);

    $this->setupInheritance();

    parent::setup();
  }

  public function getModelName()
  {
    return 'ViewRaidPlayers';
  }

}
